"""
自定义form表单验证
"""
from django import forms


class BuyGoodsForm(forms.Form):
    """
    广场表单验证
    """
    goods_id = forms.IntegerField(min_value=1)
    number = forms.IntegerField(min_value=1)

    def check_goods_id(self):
        pass


class AddGoodsForm(forms.Form):
    """
    添加积分商品表单验证
    """
    name = forms.CharField(max_length=20)
    desc = forms.CharField(max_length=50)
    detail = forms.TextInput()
